package qc.common.core.enums.qms;

import com.baomidou.mybatisplus.annotation.EnumValue;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * QMS点号数据保存受影响枚举，实际是新增还是修改（修改区分出对哪些信息进行了修改）
 *
 * @author QuCheng Tech
 * @since 2025/8/22
 */
@Getter
@AllArgsConstructor
public enum QmsPointDataSaveAffectEnum {
    ADD(0, "新增"),
    VALUE(1, "数据值"),
    BEGINV(2, "初值"),
    ENDV(4, "末值"),
    MAX(8, "最大"),
    MIN(16, "最小"),
    QUALITY(32, "数据质量");

    @EnumValue
    private int index;
    private String name;

    @Override
    public String toString() {
        if (this != null)
            return this.name;

        return null;
    }
}
